<nav class="breadcrumb" id="pathContainer">
    <i class="Hui-iconfont Hui-iconfont-weizhi"></i>
    <span>您的位置：</span>
    <span>扶贫主体管理</span>
    <span class="c-999 en">&gt;</span>
    <span class="c-primary">帮扶责任人管理</span>
</nav>
<div class="Hui-article" id="MainList">
    <div class="row cl searchBox">
        <form class="form form-horizontal responsive" id="searchForm" novalidate="novalidate">
            <div class="clearfix">
                <div class="conditionBox col-sm-2">
                    <label for="">所在乡:</label>
                    <div class="formControls">
                        <select class="select-box select radius" size="1" id="cry" value="">
                            <option value="">请选择</option>
                        </select>
                        <input type="hidden" name="country" id="h-cry">
                    </div>
                </div>
                <div class="conditionBox col-sm-2">
                    <label for="ipt1">隶属关系:</label>
                    <div class="formControls">
                        <select class="select-box select radius" size="1" name="Affiliation" id="province" value="">
                            <option value="" selected>请选择</option>
                            <option value="县（区）">县（区）</option>
                            <option value="街道、镇、乡">街道、镇、乡</option>
                            <option value="军队">军队</option>
                            <option value="村两委">村两委</option>
                        </select>
                    </div>
                </div>
                <div class="conditionBox col-sm-2">
                    <label for="ipt2">单位名称:</label>
                    <input type="text" class="input-text radius" placeholder="请输入帮扶单位名称" name="Unit_name" />
                </div>
                <div class="conditionBox col-sm-2">
                    <label for="ipt2">联系人电话:</label>
                    <input type="text" class="input-text radius" placeholder="请输入联系电话" name="work_telephone" />
                </div>
            </div>
        </form>
        <div class="clearfix search-btns btn-div">
            <input type="button" class="btn btn-primary query-btn btn-secondary float-left mr-4" value="查 询" />
            <input type="button" value="新增" class="btn btn-primary  btn-secondary" id="add-btn">
        </div>
    </div>

    <div class="container clearfix h-85p">
        <div class="col-md-6 pr-20 border-right">
            <h4 class="pl-10 border-left-blue">帮扶单位</h4>
            <div class="table-scroll">
                <table class="table table-border table-bordered">
                    <thead class="text-c row cl table-bgcolor-gary" id="thead">
                        <tr>
                            <th></th>
                            <th>序号</th>
                            <th>行政区划</th>
                            <th>帮扶单位名称</th>
                            <th>帮扶单位类型</th>
                            <th>隶属关系</th>
                            <th>联系电话</th>
                            <th>联系人姓名</th>
                            <th>联系人电话</th>
                            <th>联系人地址</th>
                            <th>邮政编码</th>
                            <th>电子邮箱</th>
                        </tr>
                    </thead>
                    <tbody class="text-c row cl" id="tbody1"></tbody>
                </table>
            </div>
            <div class="page pt-10 clearfix h-8p">
                <div class="f-l fs-08r" style="white-space: nowrap;" id="pageContainer"></div>
                <div class="f-r page-div w-37p h-20" id="pageBtn">
                    <input type="button" value="首页" class="page-btn" id="firstPage">
                    <input type="button" value="上一页" class="page-btn" id="prevPage">
                    <input type="button" value="下一页" class="page-btn" id="nextPage">
                    <input type="button" value="尾页" class="page-btn" id="lastPage">
                </div>
            </div>
        </div>
        <div class="col-md-6 pl-20">
            <h4 class="pl-10 border-left-blue">帮扶负责人</h4>
            <div class="table-scroll">
                <table class="table table-border table-bordered">
                    <thead class="text-c row cl table-bgcolor-gary" id="thead">
                        <tr>
                            <th></th>
                            <th>序号</th>
                            <th>责任人编号</th>
                            <th>姓名</th>
                            <th>性别</th>
                            <th>证件号码</th>
                            <th>职务级别</th>
                            <th>政治面貌</th>
                            <th>技术特长</th>
                            <th>联系电话</th>
                            <th>修改人</th>
                            <th>修改时间</th>
                            <th>操作</th>
                        </tr>
                    </thead>
                    <tbody class="text-c row cl" id="tbody2"></tbody>
                </table>
            </div>
        </div>
    </div>
</div>
<div style="display: ;padding-right: 70px;" class="pt-10 hpm-pop" id="add"></div>
<!-- 结对关系弹窗 -->
<div style="display: none;height: 100%;" class="pt-10 hpm-pop" id="PairingNexus">
    <div class="table-scroll2">
        <table class="table table-border table-bordered">
            <thead class="text-c row cl table-bgcolor-gary" id="thead3">
                <tr>
                    <th>序号</th>
                    <th>户编号</th>
                    <th>户主个人编号</th>
                    <th>户主姓名</th>
                    <th>户主证件号码</th>
                    <th>脱贫状态</th>
                    <th>贫困户属性</th>
                    <th>防贫原因</th>
                    <th>防贫保险</th>
                    <th>就业途径</th>
                    <th>异地搬迁户</th>
                </tr>
            </thead>
            <tbody class="text-c row cl" id="tbody3"></tbody>
        </table>
    </div>
</div>

<!-- 帮扶单位模板 -->
<script id="list1" type="text/x-handlebars-template">
    \{{#each resultList}}
    <tr>
        <td>
            <input type="radio" name="radio" value="\{{id}}" unitname="\{{unit_name}}">
        </td>
        <td>\{{Math @index '+' '1'}}</td>
        <td>\{{province}}\{{city}}\{{county}}\{{country}}</td>
        <td>\{{unitName}}</td>
        <td>\{{unitType}}</td>
        <td>\{{affiliation}}</td>
        <td>\{{tel}}</td>
        <td>\{{contacts}}</td>
        <td>\{{ContactTel}}</td>
        <td>\{{address}}</td>
        <td>\{{postCode}}</td>
        <td>\{{mail}}</td>
    </tr>
    \{{/each}}
</script>
<script id="list2" type="text/x-handlebars-template">
    \{{#each result}}
        \{{#mccmsShowIfEqual status "1"}}
        <tr>
            <td>
                <input type="checkbox" name="checkbox" value="\{{id}}">
            </td>
            <td>\{{Math @index '+' '1'}}</td>
            <td>\{{duty_id}}</td>
            <td>\{{name}}</td>
            <td>\{{sex}}</td>
            <td>\{{id_number}}</td>
            <td>\{{job_level}}</td>
            <td>\{{face}}</td>
            <td>\{{technical}}</td>
            <td>\{{telephone_number}}</td>
            <td>\{{modifier}}</td>
            <td>\{{update_time}}</td>
            <td>
                <button type="button" class="btn btn-primary size-S detail_btn" data-id="\{{id}}">编辑</button>
                <button type="button" class="btn btn-primary size-S del_btn" data-id="\{{id}}">删除</button>
                <button type="button" class="btn btn-primary size-S PairingNexus_btn" data-id="\{{id}}">结对关系</button>
            </td>
        </tr>
        \{{/mccmsShowIfEqual}}
    \{{/each}}
</script>
<!-- 结对关系模板 -->
<script id="list3" type="text/x-handlebars-template">
    \{{#each result}}
    <tr>
        <td>\{{Math @index '+' '1'}}</td>
        <td>\{{pNumber}}</td>
        <td>\{{hNumber}}</td>
        <td>\{{hName}}</td>
        <td>\{{hIdNumber}}</td>
        <td>\{{poverty}}</td>
        <td>\{{attribute}}</td>
        <td>\{{PREVENT_REASON}}</td>
        <td>\{{PREVENT_INSURANCE}}</td>
        <td>\{{EMPLOYMENT}}</td>
        <td>\{{migrate}}</td>
    </tr>
    \{{/each}}
</script>

<!-- 新增-弹窗模板  start-->
<script type="text/x-handlebars-template" id="addTpl">
    <form id="form1">
        <input type="hidden" placeholder="" class="input-text cl-input" name="id" value="\{{id}}">
        <input type="hidden" placeholder="" class="input-text cl-input" name="HELP_UNIT" value="\{{helpUnit}}">
        <input type="hidden" placeholder="" class="input-text cl-input" name="Modifier" value="\{{modifier}}">
        <input type="hidden" placeholder="" class="input-text cl-input" name="prepared_by" value="\{{prepared_by}}">
        <div class="wrapper pt-30">
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">责任人编号</label>
                <input type="number" style="width: 220px;" placeholder="请输入责任人编号" class="input-text cl-input stringCheck3" name="duty_id" value="\{{duty_id}}" required>
            </div>
            <!--<div class="row cl inline-block cl-width p_r">
                <label for="ipt2">日期</label>
                <input type="text" placeholder="请输入日期" class="input-text cl-input" name = "date" value="\{{date}}">
            </div>-->
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">姓名</label>
                <input type="text" placeholder="请输入姓名" class="input-text cl-input" name="name" value="\{{name}}" required>
            </div>
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">联系电话</label>
                <input type="text" placeholder="请输入联系电话" class="input-text cl-input telephone" name="telephone_number" value="\{{telephone_number}}">
            </div>
        </div>
        <div class="wrapper pt-30">
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">性别</label>
                <span class="select-box cl-span">
                    <select class="select cl-select" size="1" name = "sex">
                        \{{#mccmsSelect sex}}
                          <option value="" selected>请选择</option>
                          <option value="男">男</option>
                          <option value="女">女</option>
                        \{{/mccmsSelect}}
                    </select>
                </span>
            </div>
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">证件号码</label>
                <input type="text" placeholder="请输入证件号码" class="input-text cl-input Id_number" name="ID_number" value="\{{id_number}}">
            </div>
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">职务级别</label>
                <span class="select-box cl-span">
                    <select class="select cl-select" size="1" name = "job_level">
                    \{{#mccmsSelect job_level}}
                      <option value="" selected>请选择</option>
                      <option value="国家级正职">国家级正职</option>
                      <option value="国家级副职">国家级副职</option>
                      <option value="省部级正职">省部级正职</option>
                      <option value="省部级副职">省部级副职</option>
                      <option value="厅局级正职">厅局级正职</option>
                      <option value="厅局级副职">厅局级副职</option>
                      <option value="县处级正职">县处级正职</option>
                      <option value="县处级副职">县处级副职</option>
                      <option value="乡科级正职">乡科级正职</option>
                      <option value="乡科级副职">乡科级副职</option>
                      <option value="科员级">科员级</option>
                      <option value="办事员级">办事员级</option>
                      <option value="未定职">未定职</option>
                      \{{/mccmsSelect}}
                    </select>               
                </span>
            </div>
        </div>
        <div class="wrapper pt-30">
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">政治面貌</label>
                <span class="select-box cl-span">
                    <select class="select cl-select" size="1" name = "face" >
                    \{{#mccmsSelect face}}
                      <option value="" selected>请选择</option>
                      <option value="中共党员">中共党员</option>
                      <option value="中共预备党员">中共预备党员</option>
                      <option value="共青团员">共青团员</option>
                      <option value="民革会员">民革会员</option>
                      <option value="民盟盟员">民盟盟员</option>
                      <option value="民建会员">民建会员</option>
                      <option value="民进会员">民进会员</option>
                      <option value="农工党党员">农工党党员</option>
                      <option value="致公党党员">致公党党员</option>
                      <option value="九三学社社员">九三学社社员</option>
                      <option value="台盟盟员">台盟盟员</option>
                      <option value="无党派民主人士">无党派民主人士</option>
                      <option value="群众">群众</option>
                      \{{/mccmsSelect}}
                    </select>
                </span>
            </div>
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">学历</label>
                <span class="select-box cl-span">               
                    <select class="select cl-select" size="1" name = "education">
                    \{{#mccmsSelect education}}
                      <option value="" selected>请选择</option>
                      <option value="研究生及以上">研究生及以上</option>
                      <option value="博士研究生">博士研究生</option>
                      <option value="硕士研究生">硕士研究生</option>
                      <option value="大学本科">大学本科</option>
                      <option value="大学专科">大学专科</option>
                      <option value="中专技校">中专技校</option>
                      <option value="中等专科">中等专科</option>
                      <option value="职业高中">职业高中</option>
                      <option value="技工学校">技工学校</option>
                      <option value="普通高中">普通高中</option>
                      <option value="初中">初中</option>
                      <option value="小学">小学</option>
                      <option value="其它">其它</option>
                      \{{/mccmsSelect}}
                    </select>              
                </span>
            </div>
            <div class="row cl inline-block cl-width p_r">
                <label for="ipt2">技术特长</label>
                <span class="select-box cl-span">
                    <select class="select cl-select" size="1" name = "technical">
                    \{{#mccmsSelect technical}}
                      <option value="" selected>请选择</option>
                      <option value="种植">种植</option>
                      <option value="养殖">养殖</option>
                      <option value="林果">林果</option>
                      <option value="服务">服务</option>
                      \{{/mccmsSelect}}
                    </select>
                </span>
            </div>
        </div>
        <div class="wrapper pt-30">
            <!--<div class="row cl inline-block cl-width">
                <label for="ipt2">制单时间</label>
                <input type="text" placeholder="请输入新增信息的系统日期" class="input-text cl-input" name = "Prepared_time" value="\{{Prepared_time}}">
            </div>-->
        </div>
        <div class="wrapper pt-30">
            <!--<div class="row cl inline-block cl-width">
                <label for="ipt2">修改时间</label>
                <input type="text" placeholder="请输入新增或修改的系统日期" class="input-text cl-input" name = "update_time" value="\{{update_time}}">
            </div>-->
        </div>
        <div class="pt-40 pb-40">
            <input type="button" value="保存" id="save-btn" class="save-btn add-btn">
        </div>
    </form>
</script>
<!-- 新增-弹窗模板  end-->
<script id="page" type="text/x-handlebars-template">
    <span>共有\{{rowCount}}条记录，</span>
    <label for="ipt2">每页行数：</label>
    <span class="select-box page-span">
        <select class="select page-select" size="1" name="demo1" id="pageSize">
            <option value="10" selected>10</option>
            <option value="20">20</option>
            <option value="50">50</option>
            <option value="100">100</option>
            <option value="200">200</option>
            <option value="300">300</option>
        </select>
    </span>
    <label for="ipt2">当前第</label>
    <span class="select-box page-span">
        <select class="select page-select" size="1" name="demo1" id="pageCount">
            \{{#each pageCount}}
            <option value="\{{pageCount}}">\{{pageCount}}</option>
            \{{/each}}
        </select>
    </span>
    <span>页</span>
</script>
<script>
new helpPersonLiableMng();
</script>